package com.kiven.controller;

import com.kiven.service.TestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @author 1
 * @version 1.0
 * @ClassName TestController
 * @CreateDate: 2019/4/26$ 22:38$
 * @UpdateUser:
 * @UpdateDate:
 * @UpdateRemark:
 * @description todo
 */
@Controller

public class TestController {

    @Autowired
    private TestService testService;

    @RequestMapping("/testA")
    @ResponseBody
    public String testA(){
        return testService.getTestBean().getA();
    }

    @RequestMapping("/testB")
    @ResponseBody
    public String testB(){
        testService.addTestBean("1111", "222");
        return "aaa";
    }
}
